<template>
  <div class="base-chart">
    <div class="base-chart__top">
      {{ title }}
    </div>
    <div class="base-chart__container">
      <slot />
    </div>
  </div>
</template>

<script>
export default {
  name: "BaseChart",

  props: {
    title: {
      type: String,
      required: true,
    },
  },
};
</script>

<style lang="scss" scoped>
.base-chart {
  display: flex;
  flex-direction: column;
  border-radius: 5px;
  background-color: #fff;

  &:hover {
    box-shadow: 0 1px 2px -2px rgba(0, 0, 0, 0.08),
      0 3px 6px 0 rgba(0, 0, 0, 0.06), 0 5px 12px 4px rgba(0, 0, 0, 0.04);
  }

  &__top {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    padding: 12px;
    height: 50px;
    border-bottom: 1px solid #ccc;
  }

  &__container {
    box-sizing: border-box;
    min-height: 300px;
    padding: 12px;
    background-color: aqua;
  }
}
</style>
